package com.kede.ienum.order;

import com.baomidou.mybatisplus.annotation.EnumValue;
import lombok.AllArgsConstructor;
import lombok.Getter;

/***
 ** @Author:Pr.li
 ** @Description:自动清理:0=清理,1=不清理
 ** @Date: create in 2023/5/16 9:11
 ***/
@Getter
@AllArgsConstructor
public enum AuthClearLevelEnum {
    CLEAR(0,"清理",1),
    NOCLEAR(1,"不清理",2);

    @EnumValue
    private Integer code;
    private String value;
    private Integer enumIndex;

    public static AuthClearLevelEnum parse(Integer code) {
        for (AuthClearLevelEnum value : values()) {
            if (value.code.equals(code)) {
                return value;
            }
        }
        return null;
    }
}
